package com.lgx.mobile.entity;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.TableGenerator;

import com.lgx.common.entity.IdGenerator;

/**
 * @author xuyichen
 * 
 * 话题聊天记录
 *
 */
@Entity
@Table(name = "TM_M_TOPIC_CHAT_RECORD")
public class TopicChatRecord implements Serializable {
	
	private static final long serialVersionUID = 1L;

	@Id
	@GeneratedValue(strategy=GenerationType.TABLE,generator=IdGenerator.TM_M_TOPIC_CHAT_RECORD_ID)
	@TableGenerator(
			name = IdGenerator.TM_M_TOPIC_CHAT_RECORD_ID,
			table = IdGenerator.GENERATOR_TABLE,
			pkColumnName = IdGenerator.GEN_NAME,
			pkColumnValue = IdGenerator.TM_M_TOPIC_CHAT_RECORD_ID,
			valueColumnName = IdGenerator.GEN_VALUE,
			initialValue = 1,
			allocationSize = 1
	)
	private long id;
	
	/**
	 * 话题ID
	 */
	@Column(name = "topic_id")
	private long topicId;
	
	/**
	 * 用户ID
	 */
	@Column(name = "user_id")
	private long userId;
	
	/**
	 * 记录时间
	 */
	@Column(name = "record_date")
	private Date recordDate;
	
	/**
	 * 聊天内容
	 */
	private String content;

	public long getId() {
		return id;
	}

	public void setId(long id) {
		this.id = id;
	}

	public long getTopicId() {
		return topicId;
	}

	public void setTopicId(long topicId) {
		this.topicId = topicId;
	}

	public long getUserId() {
		return userId;
	}

	public void setUserId(long userId) {
		this.userId = userId;
	}

	public Date getRecordDate() {
		return recordDate;
	}

	public void setRecordDate(Date recordDate) {
		this.recordDate = recordDate;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}
}
